<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>ajax请求显示datagrid</title>
    <link rel="stylesheet" type="text/css" href="/easyui.css">
    <link rel="stylesheet" type="text/css" href="/icon.css">
    <link rel="stylesheet" type="text/css" href="/demo.css">
    <script src="/jquery.min.js"></script>
    <script src="/jquery.easyui.min.js"></script>
</head>
<body >
<h2>Basic DataGrid</h2>
<p>The DataGrid is created from markup, no JavaScript code needed.</p>
<div style="margin:20px 0;"></div>
<table id="dg"></table>

</body >
<script type="text/javascript">
 $("#dg").datagrid({
     url:"/day11/test11",
     singleSelect:true,
     dataType:'JSON',
     columns:[[
         {field:'itemid',tite:"Item ID",width:80},
         {field:'productid',width:100,title:"Product"},
         {field:'listprice',width:80,align:'right',title:"List Price"},
         {field:'unitcost',width:80,align:'right',title:"Unit Cost"},
         {field:'attr1',width:250,title:"Attribute"},
         {field:'status',width:60,align:'center',title:"Status"}
     ]]
 });
</script>
</html>